home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
DATA
/
DATA_FOR
/
1073B.ZIP
/
DISPLAY.ARC
/
STD.H
< prev
Wrap
Text File
|
1984-11-10
|
2KB
|
84 lines
/*
** STD.H
**
** Standard Utility Header for C Programs
*/
/* Conventions */
#define NULL 0
#define NIL 0
#define YES 1
#define NO 0
#define TRUE 1
#define FALSE 0
#define UNKNOWN -1
#define ABSENT -7777777
/* Pseudo Types */
/* 8 bits = 2 nibbles = 1 byte = 1 character */
typedef char BOOLEAN;
typedef char CHARACTER;
typedef char *STRING;
typedef char BYTE;
typedef char *POINTER;
/* 16 bits = 4 nibbles = 2 bytes = 2 characters = 1 word */
typedef int VOID;
typedef int INTEGER;
typedef unsigned NOMINAL;
typedef unsigned COUNT;
typedef unsigned WORD;
typedef unsigned ADDRESS;
typedef unsigned BITS;
typedef unsigned FLAGS;
/* 32 bits = 8 nibbles = 4 bytes = 4 characters = 2 words = 1 longword */
typedef long int LONG;
/* 32 bits = 4 bytes = 1 single precision float */
typedef float FLOAT;
/* 64 bits = 8 bytes = 1 double precision float */
typedef double DOUBLE;
/* Function Handles */
typedef (FUNCTION)();
typedef (*FUNCTION_LIST)();
/* Compound Data Types */
typedef union {
BYTE _byte;
WORD _word;
INTEGER _integer;
POINTER _pointer;
STRING _string;
LONG _long;
} GENERIC_STRUCT, *GENERIC;
typedef union {
unsigned _memlongword;
struct {
short unsigned _low;
short unsigned _high;
} _memword;
struct {
char _one;
char _two;
char _three;
char _four;
} _membyte;
} *MEMORY;
/* Storage Classes */
#define FAST register
#define LOCAL static
#define GLOBAL extern
/* Macros */
#define FOREVER for(;;)